home *** CD-ROM | disk | FTP | other *** search
/ Directorty Opus 5 - Magellan 2 / Opus 5 - Magellan 2.iso / Extras / hotlist_module / Install < prev    next >
Text File  |  1996-10-18  |  7KB  |  199 lines

  1. ; $VER: hotlist.module_Install 1.1 (18.10.96)
  2. ; Installer script by Leo Davidson.
  3.  
  4. ;*****************************************************************************
  5.  
  6. ;- Welcome -------------------------------------------------------------------
  7.  
  8. (welcome "hotlist.module")
  9.  
  10. ;- Introductory message ------------------------------------------------------
  11.  
  12. (message "This installer will install hotlist.module "
  13.          "for you.\n\n "
  14.          "You must already have Directory Opus 5.5 "
  15.          "correctly installed on your harddisk. ")
  16.  
  17. ;- Set where to do the install to --------------------------------------------
  18.  
  19. (set #target "DOpus5:")
  20. (set @default-dest #target)
  21.  
  22. (if (NOT (exists "DOpus5:" (noreq)))
  23.     (abort "DOpus 5.5 is not correctly installed.\n\n"
  24.            "The \"DOpus5:\" assign could not be found.")
  25. )
  26.  
  27. ;- 1) Remove the old hotlist.dopus5 ARexx module -----------------------------
  28.  
  29. (if (exists "DOpus5:modules/hotlist.dopus5")
  30.     (
  31.        (message "The old \"hotlist.dopus5\" ARexx module "
  32.                 "has been detected in \"DOpus5:modules\".\n\n"
  33.                 "You cannot use the new hotlist.module "
  34.                 "while the old one is still installed so "
  35.                 "it will be moved to \"DOpus5:storage/modules\".\n\n"
  36.                 "Note that you may have to reload Opus once "
  37.                 "the installation is complete for the new "
  38.                 "hotlist to become active.")
  39.  
  40.        (rename "DOpus5:modules/hotlist.dopus5"
  41.                "DOpus5:storage/modules/hotlist.dopus5")
  42.  
  43.        (if (exists "DOpus5:modules/hotlist.dopus5.info")
  44.            (rename "DOpus5:modules/hotlist.dopus5.info"
  45.                    "DOpus5:storage/modules/hotlist.dopus5.info")
  46.        )
  47.  
  48.     )
  49. )
  50.  
  51. (if (exists "DOpus5:system/hotlist.config")
  52.     (if (askbool (prompt "The new hotlist.module uses a different "
  53.                          "format for storing its preferences and "
  54.                          "cannot read your old hotlist prefs in "
  55.                          "\"DOpus5:system/hotlist.config\".\n\n"
  56.                          "Do you wish to delete the old file?")
  57.                  (help "If you are not sure you can always delete "
  58.                        "the file yourself at a later date.")
  59.                  (default 1)
  60.                  (choices "Delete it" "Don't delete it")
  61.         )
  62.         (delete "DOpus5:system/hotlist.config"
  63.                 (optional force)
  64.                 (infos)
  65.         )
  66.     )
  67. )
  68.  
  69. ;- 2) Install hotlist.module and guide ---------------------------------------
  70.  
  71. (copylib (prompt "\"hotlist.module\" will be copied to "
  72.                  "\"DOpus5:modules\" unless a newer version "
  73.                  "already exists.")
  74.          (help @copylib-help)
  75.          (confirm)
  76.          (source "hotlist.module")
  77.          (dest "DOpus5:modules")
  78.          (optional force)
  79. )
  80.  
  81. ; The guide has a version string and so can be copied with Copylib.
  82.  
  83. (copylib (prompt "\"hotlist.module.guide\" will be copied to "
  84.                  "\"DOpus5:help\" unless a newer version "
  85.                  "already exists.")
  86.          (help @copylib-help)
  87.          (confirm)
  88.          (source "hotlist.module.guide")
  89.          (dest "DOpus5:help")
  90.          (optional force)
  91. )
  92.  
  93. ; Only copy the guide's icon if one doesn't already exist so we don't mess-up
  94. ; the user's snapshot/image/tooltypes.
  95.  
  96. (if (NOT (exists "DOpus5:help/hotlist.module.guide.info"))
  97.     (copyfiles (prompt "An icon for the AmigaGuide will be copied.")
  98.                (help @copyfiles-help)
  99.                (source "hotlist.module.guide.info")
  100.                (dest "DOpus5:help")
  101.                (noposition)
  102.                (optional force)
  103.                (confirm)
  104.     )
  105. )
  106.  
  107. ;- 3) Install optional example button-bank -----------------------------------
  108.  
  109. (if (askbool (prompt "Would you like to install a button bank "
  110.                      "with two example Hotlist buttons which you "
  111.                      "can drag'n'drop into your existing setup?")
  112.              (help "Installing it won't hurt, but you don't "
  113.                    "have to.")
  114.              (default 1)
  115.              (choices "Yes Please" "No Thanks")
  116.     )
  117.     (
  118.        (copyfiles (source "Hotlist-examples")
  119.                   (dest "DOpus5:Buttons")
  120.                   (optional force))
  121.        (message "The example button bank has been installed.\n\n"
  122.                 "To open it, open a DOpus lister and go to "
  123.                 "\"DOpus5:Buttons\" and double-click on the "
  124.                 "file called \"Hotlist-examples\".")
  125.     )
  126. )
  127.  
  128. ;- 4) Install filetype --------------------------------------------------------
  129.  
  130. (if (AND (NOT (exists "DOpus5:Filetypes/hotlist.module Hotlist"))
  131.          (NOT (exists "DOpus5:Storage/Filetypes/hotlist.module Hotlist")))
  132.     (
  133.         (set #FTInst (askchoice (prompt "The \"hotlist.module Hotlist\" filetype "
  134.                                         "will let you double-click on a hotlist "
  135.                                         "config file to read it into a lister.\n\n"
  136.                                         "(The installer has determined that it is "
  137.                                         "not already installed.)")
  138.                                 (help "Installing it won't hurt, but you don't "
  139.                                       "have to.\n\n" @askchoice-help)
  140.                                 (choices "Install and activate."
  141.                                          "Install to storage."
  142.                                          "Don't install.")
  143.                      )
  144.         )
  145.         (if (= #FTInst 0)
  146.             (copyfiles (source "filetypes/hotlist.module Hotlist")
  147.                        (dest "DOpus5:FileTypes")
  148.                        (optional force)
  149.             )
  150.         )
  151.         (if (= #FTInst 1)
  152.             (copyfiles (source "filetypes/hotlist.module Hotlist")
  153.                        (dest "DOpus5:Storage/FileTypes")
  154.                        (optional force)
  155.             )
  156.         )
  157.     )
  158. )
  159.  
  160. ;- 5) Install catalogs --------------------------------------------------------
  161.  
  162. (copyfiles (prompt "Select which languages you would like "
  163.                    "catalogs installed for. English is "
  164.                    "built-in.")
  165.            (help @copyfiles-help)
  166.            (source "catalogs")
  167.            (dest "DOpus5:catalogs")
  168.            (choices "deutsch")
  169.            (optional force)
  170.            (confirm)
  171. )
  172.  
  173. (message "If you are willing to translate hotlist "
  174.          "into another language you can find the "
  175.          "translation files in the archive.")
  176.  
  177. ;- Misc Messages -------------------------------------------------------------
  178.  
  179. (message "Please note that if you have installed "
  180.          "MWB_DOpus 8 (which came with Opus 5.5) "
  181.          "you will have three very nice toolbar "
  182.          "icons to use for your hotlist buttons:\n\n"
  183.          "\"Hotlist.small\" (and \"Hotlist.small.info\")\n"
  184.          "\"EdHotlist.small\" (and \"EdHotlist.small.info\")\n"
  185.          "\"EdHotlist2.small\" (and \"EdHotlist2.small.info\")")
  186.  
  187. ;- All Done ------------------------------------------------------------------
  188.  
  189. (exit "hotlist.module is now installed.\n\n"
  190.       "Please take the time to read through the "
  191.       "\"hotlist.module.guide\" file in "
  192.       "\"DOpus5:Help\".\n\n"
  193.       "If it doesn't work immediately, you may "
  194.       "need to reboot or restart DOpus5.5 for the "
  195.       "new hotlist to be available."
  196.       (quiet))
  197.  
  198. ;- That's All Folks ----------------------------------------------------------
  199.